<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>
<body>
  

  <script>

    // 练习一: 定义一个函数, 打印自己的个人信息
    function printInfo() {
      console.log("my name is why")
      console.log("age is 18")
      console.log("height is 1.88")
    }

    printInfo()
    printInfo()

    // 练习二: 定义一个函数, 在内部计算10和20的和
    function sum() {
      var num1 = 10
      var num2 = 20
      var result = num1 + num2
      console.log("result:", result)
    }
    sum()

  </script>

</body>
</html>